View Javadoc

1   package net.sourceforge.simplegamenet.dice;
2   
3   import net.sourceforge.simplegamenet.specs.model.ClientEngine;
4   import net.sourceforge.simplegamenet.specs.model.GameFactory;
5   import net.sourceforge.simplegamenet.specs.model.GamePlayerClient;
6   import net.sourceforge.simplegamenet.specs.model.GameServer;
7   import net.sourceforge.simplegamenet.specs.model.ServerEngine;
8   import net.sourceforge.simplegamenet.specs.to.GameSettings;
9   import net.sourceforge.simplegamenet.specs.to.Version;
10  
11  public class DiceFactory extends GameFactory {
12  
13      public DiceFactory() {
14          super("Dice", new Version(1, 0, 0), "An interactive multiplayer game to get the "
15                  + "highest score by throwing dice and by taking the bonus as quickly as "
16                  + "possible", "Laurent Debacker");
17      }
18  
19      public GameServer createGameServer(ServerEngine serverEngine) {
20          return new DiceServer(serverEngine);
21      }
22  
23      public GamePlayerClient createGamePlayerClient(ClientEngine clientEngine) {
24          return new DicePlayerClient(clientEngine);
25      }
26  
27      public GameSettings createDefaultGameSettings() {
28          return new DiceSettings();
29      }
30  
31  }